package com.demo.springmvc底层演示.demo1;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.servlet.ModelAndView;

@Controller
public class Controller1 {
	
	@GetMapping("/test1")
	@Yml
	public User test1(HttpServletRequest request, HttpServletResponse response) {
		System.out.println("test1");
		return new User(1, "zzz");
	}
	
	@GetMapping("/test2")
	public ModelAndView test2(HttpServletRequest request, HttpServletResponse response) {
		System.out.println("test2");
		return null;
	}
	
}
